# Maintainer: Jelle van der Waa <jelle@archlinux.org>
# Contributor: Marco Kundt <mrckndt@gmail.com>

pkgname=sunxi-tools
pkgver=1.4.2
pkgrel=3
pkgdesc="A collection of command line tools for ARM devices with Allwinner SoCs"
arch=('loong64' 'x86_64')
url="https://github.com/linux-sunxi/sunxi-tools"
license=('GPL')
depends=(libusb)
source=($pkgname-$pkgver.tar.gz::https://github.com/linux-sunxi/${pkgname}/archive/v${pkgver}.tar.gz)
sha256sums=('81f48014a520cb83cac4e17f5ae627a637c4d6a422b60c693c5a705c92e43822')

build() {
  cd ${pkgname}-${pkgver}
  make
  make misc
}

package() {
  cd ${pkgname}-${pkgver}
  PREFIX="$pkgdir/usr" make install
  PREFIX="$pkgdir/usr" make install-misc
}
